﻿using System;
using System.Collections.Generic;
using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using DataAccess.Dal;
using DataAccess.DBConnections;
using dao = DataAccess.Dal.ApplicationDal;

namespace DataAccess.Bal
{
    public class ApplicationBal
    {
        private static ApplicationBal _bal;

        public static ApplicationBal GetInit()
        {
            _bal = new ApplicationBal();
            return _bal;

        }

        public bool Add(Prop.Application obj)
        {
            //Rule
            return dao.GetInstance()
                .Add(obj);
        }

        public bool Update(Prop.Application obj)
        {
            return dao.GetInstance()
                .Update(obj);
        }

        public bool Delete(Prop.Application obj)
        {
            return dao.GetInstance()
                .Delete(obj);
        }

        public IEnumerable<Prop.Application> Select(Prop.Application obj = null)
        {
            return dao.GetInstance()
                .Select(obj);
        }
        /*
        public DataTable SelectDt()
        {
            return dao.GetInstance().SelectDt();
        }
        */
    }
}
